package com.chenfei.datasource;

import com.spring4all.swagger.EnableSwagger2Doc;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.ComponentScan;

/**
 * @author chenfei
 * @description
 * @since 2018/4/11
 */
@SpringBootApplication
@ComponentScan
@MapperScan("com.chenfei.datasource.mapper")
@EnableSwagger2Doc
public class DatasourceApplication {
    public static void main(String[] args) {
        //指定启动配置文件
        /*String envPath = System.getenv(Constants.ENV_CONF_PATH.toUpperCase());
		if (StringUtils.isBlank(envPath)) {
			throw new IllegalStateException(Constants.ENV_CONF_PATH.toUpperCase() + " is blank");
		}
		if (!envPath.endsWith(File.separator))
			envPath = envPath + File.separator;
		String configPath = envPath + "config" + File.separator;
		String logPath = envPath + "log" + File.separator;
		System.setProperty("spring.config.location", configPath);
		System.setProperty("log.base", logPath);*/
        SpringApplication.run(DatasourceApplication.class);
    }
}
